﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Views/Shared/Site.Master" Inherits="System.Web.Mvc.ViewPage<MySkiPatrolSite.AdminSvc.Member>" %>



<asp:Content ID="Content1" ContentPlaceHolderID="TitleContent" runat="server">
	Member Details
</asp:Content>

<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">

<link rel="stylesheet" href="/JQuery/themes/redmond/jquery-ui.css">
<script src="//code.jquery.com/jquery-1.10.2.js"></script>
<script src="/JQuery/jquery-ui.js"></script>


 <script type="text/javascript">
     function functionAction(action) {
         document.getElementById('Action').value = action;

     }

        
    </script>

<!-- accordion script -->
<script>
    $(function () {
        $("#accordion").accordion({
            heightStyle: "content"
        });
    });
  </script>
  <% using (Html.BeginForm())
     {%>
  <%: Html.HiddenFor(model => model.ID)%>
        <input type="hidden" id="Action" name="Action" value="<%:string.Empty %>" />

<h2>Member Details - <%: Model.FullName%></h2>

<%: Html.ActionLink("Back to List", "Members")%><br /><br />

<div id="accordion">
    <h3>Member Information</h3>
    <div>
        
        <div class="editor-label">
            First Name:
            <%: Html.TextBoxFor(model => model.FirstName)%>
            <%: Html.ValidationMessageFor(model => model.FirstName)%>
        </div>

        <div class="editor-label">
            Middle Name:
            <%: Html.TextBoxFor(model => model.MiddleName)%>
            <%: Html.ValidationMessageFor(model => model.MiddleName)%>
        </div>
                
        <div class="editor-label">
            Last Name:
            <%: Html.TextBoxFor(model => model.LastName)%>
            <%: Html.ValidationMessageFor(model => model.LastName)%>
        </div>

        <div class="editor-label">
            Username:
            <%: Html.TextBoxFor(model => model.Username)%>
            <%: Html.ValidationMessageFor(model => model.Username)%>
        </div>

        <hr />
        
        <div class="editor-label">
            NSP Number:
            <%: Html.TextBoxFor(model => model.NSPNumber)%>
            <%: Html.ValidationMessageFor(model => model.NSPNumber)%>
        </div>
        

    <button type="submit" id="save" onclick="functionAction('save')">Save</button>
    <button type="submit" id="delete" onclick="functionAction('delete')">Delete</button>
</div>
<%if (Model.IDCards != null) 
  { %>
<h3>ID Cards</h3>
<div >
    <% Html.RenderPartial("_memberDetials_IDCards", Model); %>
 </div>   
 <%}
     }%>



</asp:Content>

